package team.you.ticket.dao;

import java.util.List;

import org.apache.ibatis.annotations.Param;
import team.you.ticket.pojo.Car;
import team.you.ticket.pojo.TrainName;

public interface CarMapper {
    int deleteByPrimaryKey(String id);

    int insert(Car record);

    Car selectByPrimaryKey(String id);

    List<Car> selectAll(@Param("page") Integer page,@Param("limit") Integer limit);

    int updateByPrimaryKey(Car record);

    Integer getCount();
    //按用户名查询
    Car selectByCarNum(String carNum);
    //修改键值
    Integer updateByKey(@Param("id") String id, @Param("value") String value, @Param("field") String field);
    //获取所有车牌号
    List<TrainName> selectAllCarNum();

    List<Car> selectByLike(@Param("value") String value,@Param("type") Integer type,@Param("page") Integer page,@Param("limit") Integer limit);
}